package com.si.entite;

public class Reine extends Piece {
        String pathImage1= "./src/com/ChessApps/images/4.gif";
        String pathImage2= "./src/com/ChessApps/images/11.gif";
        
	public Reine(String couleur) {
		this.couleur= couleur;
	}

	@Override
	public boolean validerDep(Position posDepart, Position posFinal) {
		int diffColonne= posFinal.x-posDepart.x;
		int diffLigne= posFinal.y-posDepart.y;
		if(this.validerEchec(posFinal)){
		if ((diffLigne==diffColonne)||(diffLigne== -diffColonne)||
			((diffColonne==0)&&(diffLigne!=0))||((diffLigne==0)&&(diffColonne!=0)))
			return true;
		return false;
	}
                return false;
        }


	public boolean manger(Position posDepart, Position posFinal) {
		
		return false;
	}
      
    @Override
    public String getPathImage(int i) {
       if (i== 1)
        {
            return pathImage1;
        }
        else {return pathImage2;}
    }

public String toString(){return "Reine";}
}
